package com.kczd.jinlan.view.mine;

import android.app.Activity;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.widget.ArrayAdapter;
import android.widget.TextView;

import com.jaredrummler.materialspinner.MaterialSpinner;
import com.kczd.jinlan.R;

/**
 * yang_g
 * 绑定安全问题
 * Created by Administrator on 2017/5/18.
 */

public class SafetyActivity extends Activity {
    private TextView id_fanhui;


   private MaterialSpinner spinner,sp_material_two,sp_material_three;
    // 适配器，到时候和Spinner连接起来
    private ArrayAdapter<String> adapter;
    private static final String[] SPINNER_ONE = {"你的爸爸叫什么?", "你的妈妈叫什么", "你的爸爸叫什么", "你的妈妈叫什么", "你的姐姐叫什么"};
    private static final String[] SPINNER_TWO = {"你的爸爸叫什么?", "你的妈妈叫什么", "你的爸爸叫什么", "你的妈妈叫什么", "你的妈妈叫什么"};
    private static final String[] SPINNER_THREE = {"你的妈妈叫什么?", "你的妈妈叫什么", "你的妈妈叫什么", "你的妈妈叫什么", "你的姐姐叫什么"};

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.safety_activity);
    }

    @Override
    public void onContentChanged() {
        super.onContentChanged();
        spinner = (MaterialSpinner) findViewById(R.id.sp_material);
        spinner.setItems(SPINNER_ONE);
        spinner.setOnItemSelectedListener(new MaterialSpinner.OnItemSelectedListener<String>() {
            @Override
            public void onItemSelected(MaterialSpinner view, int position, long id, String item) {

            }
        });


        sp_material_two = (MaterialSpinner) findViewById(R.id.sp_material_two);
        sp_material_two.setItems(SPINNER_TWO);
        sp_material_two.setOnItemSelectedListener(new MaterialSpinner.OnItemSelectedListener<String>() {
            @Override
            public void onItemSelected(MaterialSpinner view, int position, long id, String item) {

            }
        });

        sp_material_three = (MaterialSpinner) findViewById(R.id.sp_material_three);
        sp_material_three.setItems(SPINNER_THREE);
        sp_material_three.setOnItemSelectedListener(new MaterialSpinner.OnItemSelectedListener<String>() {
            @Override
            public void onItemSelected(MaterialSpinner view, int position, long id, String item) {

            }
        });

    }


}
